<div class="am-cf am-padding-xs am-padding-bottom-0">
	<div class="am-fl am-cf">
		<strong class="am-text-primary am-text-lg">redis管理工具</strong> / <small>首页</small>
	</div>
	<div class="am-fr am-cf">
		<button type="button" class="am-btn am-btn-xs am-btn-primary" id="refreshBtn">
			<i class="am-icon-refresh"></i>&nbsp;刷新
		</button>
	</div>
</div>
<hr class="am-margin-xs"/>
<ul class="am-avg-sm-1 am-avg-md-4 am-margin-xs am-padding-xs am-text-center admin-content-list ">
	<li>
		<a href="javascript:void(0);" class="am-text-success">
			<span class="am-icon-btn am-icon-user"></span><br />
			key数量<br />
			<span id="keySize"></span>
		</a>
	</li>
	<li>
		<a href="javascript:void(0);" class="am-text-warning">
			<span class="am-icon-btn am-icon-briefcase"></span><br />
			客户端数量<br />
			<span id="clientSize"></span>
		</a>
	</li>
	<li>
		<a href="javascript:void(0);" class="am-text-danger">
			<span class="am-icon-btn am-icon-recycle"></span><br />
			master数量<br />
			<span id="masterSize"></span>
		</a>
	</li>
	<li>
		<a href="javascript:void(0);" class="am-text-secondary">
			<span class="am-icon-btn am-icon-user-md"></span><br />
			slave数量<br />
			<span id="slaveSize"></span>
		</a>
	</li>
</ul>
<div class="am-g">
	<div class="am-u-md-12 am-padding-xs">
		<div class="am-panel am-panel-default">
			<div class="am-panel-hd am-cf" data-am-collapse="{target: '#collapse-panel-4'}">
				消息<span class="am-icon-chevron-down am-fr"></span>
			</div>
			<div id="collapse-panel-4" class="am-panel-bd am-collapse am-in">
				<ul class="am-list admin-content-task">
					<li>
						<div class="admin-task-meta">2017-11-23 16:20:00 admin</div>
						<div class="admin-task-bd">
							v1.2.0：<br/>
							1. 增加hash结构数据的查询<br/>
							2. 增加key序列化的切换<br/>
							3. 正则查询keys时，避免jdk序列化的key数据显示乱码的问题
						</div>
					</li>
					<li>
						<div class="admin-task-meta">2017-09-30 15:48:29 admin</div>
						<div class="admin-task-bd">
							v1.1.0：<br/>
							1. 部分页面内容手动触发查询，避免进入页面后因为查询缓慢导致不能操作<br/>
							2. 增加根据key正则进行查询的功能
						</div>
					</li>
					<li>
						<div class="admin-task-meta">2017-05-12 17:35:23 admin</div>
						<div class="admin-task-bd">
							v1.0.0：<br/>
							基本信息的查询
						</div>
					</li>
				</ul>
			</div>
		</div>
	</div>
</div>
<script>
(function(){
	$('#refreshBtn').on('click', function(){
		$.ajax({
			url: basePath + 'redis/home',
			type: 'get',
			dataType: 'json',
			success: function(data){
				for(var key in data){
					if($('#' + key)){
						$('#' + key).text(data[key]);
					}
				}
			}
		});
	});
})();
</script>